package com.base.service.impl;

import java.math.BigDecimal;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.base.mapper.voipmapper.SelfShopOrderMapper;
import com.base.po.voip.SelfShopOrder;
import com.base.po.voip.SelfShopOrderExample;
import com.base.service.SelfShopOrderService;
import com.base.utils.Page;

@Service("selfShopOrderService")
public class SelfShopOrderServiceImpl implements SelfShopOrderService{
	
	@Autowired
	private SelfShopOrderMapper selfShopOrderMapper;

	@Override
	public int countByExample(SelfShopOrderExample example) {
		
		return selfShopOrderMapper.countByExample(example);
	}

	@Override
	public int deleteByExample(SelfShopOrderExample example) {
		
		return selfShopOrderMapper.deleteByExample(example);
	}

	@Override
	public int insert(SelfShopOrder record) {
		
		return selfShopOrderMapper.insert(record);
	}

	@Override
	public int insertSelective(SelfShopOrder record) {
		
		return selfShopOrderMapper.insertSelective(record);
	}

	@Override
	public List<SelfShopOrder> selectByExample(SelfShopOrderExample example) {
		
		return selfShopOrderMapper.selectByExample(example);
	}

	@Override
	public int updateByExampleSelective(SelfShopOrder record, SelfShopOrderExample example) {
		
		return selfShopOrderMapper.updateByExampleSelective(record, example);
	}

	@Override
	public int updateByExample(SelfShopOrder record, SelfShopOrderExample example) {
		
		return selfShopOrderMapper.updateByExample(record, example);
	}

	@Override
	public List<SelfShopOrder> selectByMobile(String mobile, String parentid, String shopid) {
		
		return selfShopOrderMapper.selectByMobile(mobile, parentid, shopid);
	}

	@Override
	public SelfShopOrder selectByPrimaryKey(String id) {
		
		return selfShopOrderMapper.selectByPrimaryKey(id);
	}

	@Override
	public SelfShopOrder selectByOrderID(String orderid) {
		return selfShopOrderMapper.selectByOrderID(orderid);
	}

	@Override
	public List<SelfShopOrder> selectByID(String id) {
		return selfShopOrderMapper.selectByID(id);
	}

	@Override
	public int updateByPrimaryKeySelective(SelfShopOrder record) {
		
		return selfShopOrderMapper.updateByPrimaryKeySelective(record);
	}

	@Override
	public List<SelfShopOrder> selectAllOrder(Page page, String mobile, String parentid, String shopid) {
		
		return selfShopOrderMapper.selectAllOrder(page, mobile, parentid, shopid);
	}

	@Override
	public List<SelfShopOrder> selectByAll(Page page, String parentid, String shopid, String mobile, String ordernum, String goodstext, Byte status, Byte deliverystatus, String supplier, String createtime,int role) {
		return selfShopOrderMapper.selectByAll(page, parentid, shopid, mobile, ordernum, goodstext, status, deliverystatus, supplier, createtime,role);
	}

	@Override
	public int countAllOrder(String mobile, String parentid, String shopid) {
		
		return selfShopOrderMapper.countAllOrder(mobile, parentid, shopid);
	}

	@Override
	public int countByAll(String parentid, String shopid, String mobile, String ordernum, String goodstext, Byte status, Byte deliverystatus, String supplier, String createtime,int role) {
		return selfShopOrderMapper.countByAll(parentid, shopid, mobile, ordernum, goodstext, status, deliverystatus, supplier, createtime,role);
	}

	@Override
	public List<SelfShopOrder> selectTransaction(Page page, String parentid, String shopid) {
		return selfShopOrderMapper.selectTransaction(page, parentid, shopid);
	}

	@Override
	public List<SelfShopOrder> selectByIsTakeOver(String parentid, Integer istakeover) {
		return selfShopOrderMapper.selectByIsTakeOver(parentid, istakeover);
	}

	@Override
	public int countTransaction(String parentid, String shopid) {
		return selfShopOrderMapper.countTransaction(parentid, shopid);
	}

	@Override
	public BigDecimal sumAllCash(String parentid, String shopid) {
		
		return selfShopOrderMapper.sumAllCash(parentid, shopid);
	}

	@Override
	public BigDecimal sumCanCash(String parentid, String shopid, String cleartime, String nowtime) {
		
		return selfShopOrderMapper.sumCanCash(parentid, shopid, cleartime, nowtime);
	}

	@Override
	public List<SelfShopOrder> selectBySelfShopID(String id,String fMobile,String fOrderNum,String fSupplier,Byte status,String fCreatetime,Page page) {
		return selfShopOrderMapper.selectBySelfShopID( id, fMobile, fOrderNum, fSupplier, status, fCreatetime,page);
	}

	@Override
	public List<SelfShopOrder> selectBySelfShopIDALL(String id, String fMobile, String fOrderNum, String fSupplier, Byte status, String fCreatetime) {
		return selfShopOrderMapper.selectBySelfShopIDALL( id, fMobile, fOrderNum, fSupplier, status, fCreatetime);
	}

	@Override
	public Integer countByShopId(String id,String fMobile,String fOrderNum,String fSupplier,Byte status,String fCreatetime) {
		return selfShopOrderMapper.countByShopId(id, fMobile, fOrderNum, fSupplier, status, fCreatetime);
	}

	@Override
	public List<SelfShopOrder> selectAllbyDatetime(String selfShopId, String dateime1, String datetime2) {
		return selfShopOrderMapper.selectAllbyDatetime( selfShopId,  dateime1,  datetime2) ;
	}

	@Override
	public List<SelfShopOrder> selectByAllNoPage(String parentid, String shopid, String mobile, String ordernum, String goodstext, Byte status, Byte deliverystatus, String supplier, String createtime,int role) {
		return selfShopOrderMapper.selectByAllNoPage( parentid, shopid, mobile, ordernum, goodstext, status, deliverystatus, supplier, createtime,role);
	}
}
